#include <iostream>
using namespace std;
#include <vector>

int dpfib(int n)
{
  if (n <= 2)
  {
    return 1;
  }

  int i = 1;
  int j = 1;
  int k = 0;

  while (n-2)
  {
    k = i + j;
    i = j;
    j = k; 
    n--;
  }

  return k;
}



int main()
{
  cout << dpfib(5) << endl;
}
